package Stream.并行流;

import java.util.List;
import java.util.stream.Collectors;

public class Collect {
    public static void main(String[] args) {
        List<String> collect = List.of("D", "A", "N", "d", "i", "n", "g").parallelStream()
                .map(String::toLowerCase)
                .collect(Collectors.toList());
        System.out.println(collect);
        //   collect和foreachOrder很相似,只不过它把结果收集整理了起来
    }
}
